home *** CD-ROM | disk | FTP | other *** search
/ Amiga Plus Leser 15 / Amiga Plus Leser CD 15.iso / Tools / Development / yacas_alg / yacas_morphos / share / yacas / random.rep / code.ys < prev   
Encoding:
Text File  |  2002-03-13  |  405 b   |  18 lines

  1.  
  2.  
  3. RandSeed:=0;
  4.  
  5. Function("Random",{im,ia,ic})
  6. [
  7.   RandSeed:=MathMod(RandSeed*ia+ic,im);
  8.   N(RandSeed/(im-1));
  9. ];
  10.  
  11. Function("Random1",{}) Random(4294967296,1103515245,12345);
  12. Function("Random2",{}) Random(6075,106,1283);
  13. Function("Random3",{}) Random(81000,421,17117);
  14. Function("Random4",{}) Random(1771875,2416,374441);
  15. Function("Random5",{}) Random(217728,84589,45989);
  16.  
  17. Function("Random",{}) Random5();
  18.